Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

arch

Package Overview
Dependencies
Maintainers
2
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

arch

Better `os.arch()` for node and the browser -- detect OS architecture

  • 2.2.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
7.3M
decreased by-14.04%
Maintainers
2
Weekly downloads
 
Created

What is arch?

The 'arch' npm package is a simple utility that allows you to detect the architecture of the processor on which the Node.js process is running. It can be used to determine whether the system is running on a 32-bit or a 64-bit architecture, which can be useful for conditional logic based on system architecture, such as choosing the correct binary to execute or the right dependency to install.

What are arch's main functionalities?

Detecting processor architecture

This feature allows you to detect the architecture of the processor. The 'arch()' function returns a string indicating the architecture, such as 'x64' for 64-bit or 'x86' for 32-bit systems.

"use strict";
const arch = require('arch');
console.log(arch()); // 'x64' or 'x86' depending on the system architecture

Other packages similar to arch

Keywords

FAQs

Package last updated on 27 Oct 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc